<script setup>
import {ref} from "vue";

let toy = ref("奥特曼")
defineExpose({toy})

function func(parent) {
  console.log(parent) // 父组件实例
}
</script>

<template>
  <button @click="func($parent)">按钮</button>
</template>

<style scoped>

</style>